/* 重置与基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Courier New', monospace;
}

body {
    background-color: #0a0a14;
    color: #00f3ff;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

/* 赛博朋克背景 */
.cyber-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.grid-lines {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(to right, rgba(0, 243, 255, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 243, 255, 0.05) 1px, transparent 1px);
    background-size: 40px 40px;
}

.grid-dots {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(0, 243, 255, 0.2) 1px, transparent 1px);
    background-size: 30px 30px;
}

.scan-line {
    position: absolute;
    width: 100%;
    height: 4px;
    background: linear-gradient(to bottom, transparent, rgba(0, 243, 255, 0.6), transparent);
    animation: scan 4s linear infinite;
    box-shadow: 0 0 15px #00f3ff;
}

@keyframes scan {
    0% { top: 0%; }
    100% { top: 100%; }
}

/* 主容器 */
.cyber-container {
    display: flex;
    height: 100vh;
    width: 100vw;
    padding: 15px;
    gap: 15px;
    position: relative;
}

/* 左侧特效面板 */
.effects-panel {
    flex: 0 0 320px;
    background: rgba(10, 15, 30, 0.85);
    border: 1px solid #00f3ff;
    border-radius: 8px;
    box-shadow: 
        0 0 20px rgba(0, 243, 255, 0.3),
        inset 0 0 30px rgba(0, 243, 255, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.panel-header {
    padding: 20px;
    border-bottom: 1px solid rgba(0, 243, 255, 0.3);
}

.cyber-title {
    color: #00f3ff;
    font-size: 1.5rem;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    text-shadow: 0 0 10px #00f3ff;
}

.search-box {
    position: relative;
    margin-top: 10px;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #00f3ff;
}

.search-box input {
    width: 100%;
    padding: 10px 15px 10px 35px;
    background: rgba(5, 10, 20, 0.8);
    border: 1px solid #00f3ff;
    border-radius: 4px;
    color: #00f3ff;
    font-size: 0.9rem;
}

.search-box input:focus {
    outline: none;
    box-shadow: 0 0 10px #00f3ff;
}

/* 特效列表 */
.effects-list {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.effect-item {
    padding: 12px 15px;
    margin-bottom: 8px;
    background: rgba(15, 25, 45, 0.6);
    border: 1px solid rgba(0, 243, 255, 0.2);
    border-radius: 4px;
    color: #a0f6ff;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.effect-item:hover {
    background: rgba(20, 40, 80, 0.8);
    border-color: #00f3ff;
    transform: translateX(5px);
    box-shadow: 0 0 15px rgba(0, 243, 255, 0.4);
}

.effect-item.active {
    background: rgba(0, 50, 100, 0.8);
    border-color: #ff00ff;
    color: #ff00ff;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.5);
}

.effect-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 243, 255, 0.2), transparent);
    transition: left 0.5s;
}

.effect-item:hover::before {
    left: 100%;
}

.effect-name {
    font-weight: bold;
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.effect-tags {
    font-size: 0.75rem;
    color: #00ccff;
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.effect-tag {
    background: rgba(0, 150, 200, 0.2);
    padding: 2px 6px;
    border-radius: 10px;
}

.panel-footer {
    padding: 15px;
    border-top: 1px solid rgba(0, 243, 255, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stats {
    font-size: 0.9rem;
    color: #80e1ff;
}

/* 按钮样式 */
.cyber-button {
    padding: 10px 20px;
    background: linear-gradient(45deg, #003366, #0066cc);
    border: 1px solid #00f3ff;
    border-radius: 4px;
    color: #00f3ff;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
}

.cyber-button:hover {
    background: linear-gradient(45deg, #004488, #0088ff);
    box-shadow: 0 0 15px #00f3ff;
    transform: translateY(-2px);
}

.cyber-button:active {
    transform: translateY(1px);
}

.cyber-button.small {
    padding: 8px 15px;
    font-size: 0.9rem;
}

.cyber-button.tiny {
    padding: 5px 10px;
    font-size: 0.8rem;
}

/* 右侧预览面板 */
.preview-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.preview-header {
    background: rgba(10, 15, 30, 0.85);
    border: 1px solid #00f3ff;
    border-radius: 8px;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 0 15px rgba(0, 243, 255, 0.2);
    backdrop-filter: blur(5px);
}

.control-buttons {
    display: flex;
    gap: 10px;
}

/* 预览区域 */
.preview-area {
    flex: 1;
    display: flex;
    gap: 15px;
}

.effect-display {
    flex: 1;
    background: rgba(5, 10, 20, 0.9);
    border: 1px solid #00f3ff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 30px rgba(0, 10, 30, 0.8);
}

.default-preview {
    text-align: center;
    color: #80e1ff;
    z-index: 1;
}

.cyber-grid {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 243, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 243, 255, 0.05) 1px, transparent 1px);
    background-size: 30px 30px;
}

.welcome-text i {
    font-size: 3rem;
    color: #00f3ff;
    margin-bottom: 15px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.7; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.1); }
}

.welcome-text h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #00f3ff;
}

.welcome-text p {
    color: #80e1ff;
}

.parameters-panel {
    flex: 0 0 280px;
    background: rgba(10, 15, 30, 0.85);
    border: 1px solid #00f3ff;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(5px);
}

.parameters-panel h3 {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.params-container {
    flex: 1;
    overflow-y: auto;
}

.param-group {
    margin-bottom: 15px;
}

.param-label {
    display: block;
    margin-bottom: 5px;
    color: #80e1ff;
    font-size: 0.9rem;
}

.param-control {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
}

.param-control input[type="range"] {
    flex: 1;
    height: 6px;
    background: rgba(0, 50, 100, 0.5);
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
}

.param-control input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    background: #00f3ff;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px #00f3ff;
}

.param-control input[type="color"] {
    width: 40px;
    height: 30px;
    border: 1px solid #00f3ff;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
}

.param-value {
    min-width: 40px;
    text-align: center;
    color: #00f3ff;
    font-weight: bold;
}

/* 代码面板 */
.code-panel {
    height: 300px;
    background: rgba(10, 15, 30, 0.9);
    border: 1px solid #00f3ff;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.code-header {
    padding: 12px 15px;
    border-bottom: 1px solid rgba(0, 243, 255, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.code-actions {
    display: flex;
    gap: 8px;
}

.code-editor {
    flex: 1;
    position: relative;
    overflow: hidden;
}

.code-editor textarea {
    width: 100%;
    height: 100%;
    background: rgba(5, 10, 20, 0.9);
    border: none;
    padding: 15px;
    color: #80e1ff;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: none;
    outline: none;
    position: relative;
    z-index: 2;
}

.code-highlight {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 15px;
    pointer-events: none;
    z-index: 1;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    white-space: pre-wrap;
    overflow: auto;
}

/* 通知 */
.cyber-notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 15px 20px;
    background: rgba(10, 30, 50, 0.9);
    border: 1px solid #00f3ff;
    border-radius: 4px;
    color: #00f3ff;
    box-shadow: 0 0 20px rgba(0, 243, 255, 0.5);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.5s;
    z-index: 1000;
}

.cyber-notification.show {
    transform: translateY(0);
    opacity: 1;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(5, 10, 20, 0.5);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 243, 255, 0.5);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 243, 255, 0.8);
}

/* 响应式调整 */

/* 大屏幕适配 (1400px以上) */
@media (min-width: 1400px) {
    .cyber-container {
        padding: 20px;
        gap: 20px;
    }
    
    .effects-panel {
        flex: 0 0 380px;
    }
    
    .panel-header {
        padding: 25px;
    }
    
    .cyber-title {
        font-size: 1.8rem;
    }
    
    .effect-item {
        padding: 15px 20px;
        margin-bottom: 10px;
    }
    
    .effect-name {
        font-size: 1.1rem;
    }
    
    .preview-header {
        padding: 20px 25px;
    }
    
    .parameters-panel {
        flex: 0 0 320px;
        padding: 20px;
    }
    
    .code-panel {
        height: 350px;
    }
    
    .cyber-button {
        padding: 12px 25px;
        font-size: 1.1rem;
    }
}

/* 中等屏幕适配 (1200px - 1400px) */
@media (max-width: 1400px) and (min-width: 1201px) {
    .cyber-container {
        padding: 15px;
        gap: 15px;
    }
    
    .effects-panel {
        flex: 0 0 340px;
    }
    
    .parameters-panel {
        flex: 0 0 300px;
    }
    
    .code-panel {
        height: 320px;
    }
}

/* 平板横屏适配 (992px - 1200px) */
@media (max-width: 1200px) {
    .cyber-container {
        flex-direction: row;
        padding: 12px;
        gap: 12px;
    }
    
    .effects-panel {
        flex: 0 0 280px;
    }
    
    .panel-header {
        padding: 15px;
    }
    
    .cyber-title {
        font-size: 1.3rem;
        margin-bottom: 10px;
    }
    
    .search-box input {
        padding: 8px 12px 8px 30px;
        font-size: 0.85rem;
    }
    
    .effect-item {
        padding: 10px 12px;
        margin-bottom: 6px;
    }
    
    .effect-name {
        font-size: 0.95rem;
    }
    
    .preview-area {
        flex-direction: row;
    }
    
    .parameters-panel {
        flex: 0 0 250px;
        padding: 12px;
    }
    
    .code-panel {
        height: 280px;
    }
    
    .cyber-button {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
}

/* 平板竖屏适配 (768px - 992px) */
@media (max-width: 992px) {
    body {
        overflow: auto;
        height: auto;
    }
    
    .cyber-container {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
        padding: 10px;
        gap: 10px;
    }
    
    .effects-panel {
        flex: 0 0 auto;
        max-height: 250px;
        width: 100%;
    }
    
    .effects-list {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        padding: 10px;
    }
    
    .effect-item {
        flex: 1;
        min-width: 200px;
        margin-bottom: 0;
        padding: 10px 12px;
    }
    
    .preview-panel {
        width: 100%;
    }
    
    .preview-area {
        flex-direction: column;
        gap: 10px;
    }
    
    .effect-display {
        min-height: 300px;
    }
    
    .parameters-panel {
        flex: 0 0 auto;
        width: 100%;
        max-height: 250px;
    }
    
    .code-panel {
        height: 250px;
    }
    
    .welcome-text i {
        font-size: 2.5rem;
    }
    
    .welcome-text h3 {
        font-size: 1.3rem;
    }
}

/* 手机横屏适配 (600px - 768px) */
@media (max-width: 768px) {
    .cyber-container {
        padding: 8px;
        gap: 8px;
    }
    
    .effects-panel {
        max-height: 200px;
    }
    
    .panel-header {
        padding: 12px;
    }
    
    .cyber-title {
        font-size: 1.2rem;
        margin-bottom: 8px;
    }
    
    .search-box input {
        padding: 8px 10px 8px 28px;
        font-size: 0.8rem;
    }
    
    .effects-list {
        padding: 8px;
        gap: 6px;
    }
    
    .effect-item {
        min-width: 150px;
        padding: 8px 10px;
    }
    
    .effect-name {
        font-size: 0.9rem;
    }
    
    .effect-tags {
        font-size: 0.7rem;
    }
    
    .panel-footer {
        padding: 10px 12px;
    }
    
    .stats {
        font-size: 0.8rem;
    }
    
    .preview-header {
        padding: 12px 15px;
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .control-buttons {
        width: 100%;
        justify-content: flex-end;
    }
    
    .effect-display {
        min-height: 250px;
    }
    
    .parameters-panel {
        max-height: 200px;
        padding: 10px;
    }
    
    .param-group {
        margin-bottom: 10px;
    }
    
    .param-label {
        font-size: 0.85rem;
    }
    
    .code-panel {
        height: 220px;
    }
    
    .code-header {
        padding: 10px 12px;
    }
    
    .code-editor textarea,
    .code-highlight {
        padding: 12px;
        font-size: 0.85rem;
    }
    
    .cyber-button {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
    
    .cyber-button.small {
        padding: 5px 10px;
        font-size: 0.8rem;
    }
    
    .welcome-text i {
        font-size: 2rem;
    }
    
    .welcome-text h3 {
        font-size: 1.1rem;
    }
    
    .welcome-text p {
        font-size: 0.9rem;
    }
    
    .cyber-notification {
        left: 10px;
        right: 10px;
        bottom: 10px;
    }
}

/* 手机竖屏适配 (480px - 600px) */
@media (max-width: 600px) {
    .cyber-container {
        padding: 6px;
        gap: 6px;
    }
    
    .effects-panel {
        max-height: 180px;
        border-radius: 6px;
    }
    
    .panel-header {
        padding: 10px;
    }
    
    .cyber-title {
        font-size: 1rem;
        margin-bottom: 6px;
    }
    
    .cyber-title i {
        font-size: 1.1rem;
    }
    
    .search-box input {
        padding: 6px 8px 6px 25px;
        font-size: 0.75rem;
    }
    
    .search-box i {
        left: 8px;
        font-size: 0.9rem;
    }
    
    .effects-list {
        padding: 6px;
        gap: 5px;
    }
    
    .effect-item {
        min-width: 130px;
        padding: 6px 8px;
        border-radius: 3px;
    }
    
    .effect-name {
        font-size: 0.85rem;
        margin-bottom: 3px;
    }
    
    .effect-tags {
        font-size: 0.65rem;
        gap: 3px;
    }
    
    .effect-tag {
        padding: 1px 4px;
    }
    
    .panel-footer {
        padding: 8px 10px;
    }
    
    .stats {
        font-size: 0.75rem;
    }
    
    .preview-header {
        padding: 10px 12px;
        border-radius: 6px;
    }
    
    .preview-header h2 {
        font-size: 1rem;
    }
    
    .control-buttons {
        gap: 6px;
    }
    
    .preview-area {
        gap: 8px;
    }
    
    .effect-display {
        min-height: 200px;
        border-radius: 6px;
    }
    
    .parameters-panel {
        max-height: 180px;
        padding: 8px;
        border-radius: 6px;
    }
    
    .parameters-panel h3 {
        font-size: 0.95rem;
        margin-bottom: 10px;
    }
    
    .param-group {
        margin-bottom: 8px;
    }
    
    .param-label {
        font-size: 0.8rem;
        margin-bottom: 3px;
    }
    
    .param-control {
        gap: 6px;
    }
    
    .param-value {
        font-size: 0.85rem;
        min-width: 35px;
    }
    
    .code-panel {
        height: 180px;
        border-radius: 6px;
    }
    
    .code-header {
        padding: 8px 10px;
    }
    
    .code-header h3 {
        font-size: 0.9rem;
    }
    
    .code-actions {
        gap: 5px;
    }
    
    .code-editor textarea,
    .code-highlight {
        padding: 10px;
        font-size: 0.8rem;
        line-height: 1.4;
    }
    
    .cyber-button {
        padding: 5px 10px;
        font-size: 0.8rem;
        border-radius: 3px;
    }
    
    .cyber-button.small {
        padding: 4px 8px;
        font-size: 0.75rem;
    }
    
    .cyber-button.tiny {
        padding: 3px 6px;
        font-size: 0.7rem;
    }
    
    .welcome-text i {
        font-size: 1.8rem;
        margin-bottom: 10px;
    }
    
    .welcome-text h3 {
        font-size: 1rem;
        margin-bottom: 8px;
    }
    
    .welcome-text p {
        font-size: 0.8rem;
    }
    
    .cyber-notification {
        padding: 12px 15px;
        font-size: 0.9rem;
    }
}

/* 小屏手机适配 (480px以下) */
@media (max-width: 480px) {
    .cyber-container {
        padding: 4px;
        gap: 4px;
    }
    
    .effects-panel {
        max-height: 150px;
        border-radius: 4px;
    }
    
    .panel-header {
        padding: 8px;
    }
    
    .cyber-title {
        font-size: 0.9rem;
        margin-bottom: 5px;
        gap: 6px;
    }
    
    .cyber-title i {
        font-size: 1rem;
    }
    
    .search-box input {
        padding: 5px 6px 5px 22px;
        font-size: 0.7rem;
    }
    
    .search-box i {
        left: 6px;
        font-size: 0.8rem;
    }
    
    .effects-list {
        padding: 5px;
        gap: 4px;
    }
    
    .effect-item {
        min-width: 110px;
        padding: 5px 6px;
        border-radius: 3px;
    }
    
    .effect-name {
        font-size: 0.8rem;
        gap: 5px;
    }
    
    .effect-tags {
        font-size: 0.6rem;
        gap: 2px;
    }
    
    .effect-tag {
        padding: 1px 3px;
        border-radius: 8px;
    }
    
    .panel-footer {
        padding: 6px 8px;
    }
    
    .stats {
        font-size: 0.7rem;
    }
    
    .preview-header {
        padding: 8px 10px;
        border-radius: 4px;
        gap: 8px;
    }
    
    .preview-header h2 {
        font-size: 0.9rem;
    }
    
    .control-buttons {
        gap: 4px;
        width: 100%;
    }
    
    .preview-area {
        gap: 6px;
    }
    
    .effect-display {
        min-height: 180px;
        border-radius: 4px;
    }
    
    .welcome-text i {
        font-size: 1.5rem;
        margin-bottom: 8px;
    }
    
    .welcome-text h3 {
        font-size: 0.9rem;
    }
    
    .welcome-text p {
        font-size: 0.75rem;
    }
    
    .parameters-panel {
        max-height: 150px;
        padding: 6px;
        border-radius: 4px;
    }
    
    .parameters-panel h3 {
        font-size: 0.85rem;
        margin-bottom: 8px;
        gap: 6px;
    }
    
    .param-group {
        margin-bottom: 6px;
    }
    
    .param-label {
        font-size: 0.75rem;
    }
    
    .param-control input[type="range"] {
        height: 4px;
    }
    
    .param-control input[type="range"]::-webkit-slider-thumb {
        width: 12px;
        height: 12px;
    }
    
    .param-control input[type="color"] {
        width: 30px;
        height: 24px;
    }
    
    .param-value {
        font-size: 0.8rem;
        min-width: 30px;
    }
    
    .code-panel {
        height: 150px;
        border-radius: 4px;
    }
    
    .code-header {
        padding: 6px 8px;
    }
    
    .code-header h3 {
        font-size: 0.8rem;
    }
    
    .code-actions {
        gap: 4px;
    }
    
    .code-editor textarea,
    .code-highlight {
        padding: 8px;
        font-size: 0.75rem;
        line-height: 1.3;
    }
    
    .cyber-button {
        padding: 4px 8px;
        font-size: 0.75rem;
        border-radius: 3px;
        gap: 4px;
    }
    
    .cyber-button.small {
        padding: 3px 6px;
        font-size: 0.7rem;
    }
    
    .cyber-button.tiny {
        padding: 2px 5px;
        font-size: 0.65rem;
    }
    
    .cyber-notification {
        padding: 10px 12px;
        font-size: 0.85rem;
        left: 5px;
        right: 5px;
        bottom: 5px;
    }
    
    /* 滚动条小屏优化 */
    ::-webkit-scrollbar {
        width: 5px;
        height: 5px;
    }
}